#include<iostream>
#include<cstdlib>
#include<cstdlib>
#define N 100010
using namespace std;

typedef struct a{
	int *point;
	int rear,front;//rear是尾部
}queue;

int pop(queue *p,int flag){//flag=0就是前面删除，flag=1就是队尾删除
	int ans;
	ans=flag?(p->point[p->front--]):(p->point[p->rear++]);
	return ans;
}

void push(queue *p,int data){
	p->point[++(p->rear)]=data;
}

int size(queue *point){
	return point->rear-point->front;
}

int main(){
	queue *p;
	p=(queue*)malloc(sizeof(queue));
	p->point=(int*)malloc(sizeof(int)*N);
	p->rear=-1;
	p->front=0;
	int d[N];
	int a,b;
	cin>>a>>b;
	for(int i=0;i<a;i++){
		cin>>d[i];
	}
	for(int i=0;i<a;i++){
		while(size(p)&&p->point[p->rear]>d[i])
			pop(p,1);
		push(p,d[i]);
		if(i+1>b&&
	}
}	